package a.e.a;

import a.c.q;
import a.c.z;
import a.d.w;
import a.i.ib;
import a.i.n;
import a.j.ab;
import a.j.*;

import java.util.*;

public class s
  extends r
{
  private z g;
  private tb h;
  private y i = new y();
  private Collection j = new ArrayList();
  private a_ k;
  static final Map l = new HashMap();
  public static int m;
  
  public s()
  {
    a("Line", this.i);
  }
  
  public void a(String paramString1, String paramString2)
  {
    super.a(paramString1, paramString2);
    if ((r.f) || ("arrow".equals(paramString1))) {
      this.j.add(paramString2);
    }
  }
  
  public void a(String paramString)
  {
    if ("styleproperties".equals(paramString))
    {
      this.k = new a_(null);
      a(paramString, this.k);
    }
    super.a(paramString);
  }
  
  public void a()
  {
    super.a();
    this.h = null;
    this.g = null;
    this.j.clear();
  }
  
  public void a(r paramr)
  {
    if (paramr == this.i) {
      this.g = this.i.f();
    }
  }
  
  public void b()
  {
    boolean bool = r.f;
    int i1 = r.e;
    Object localObject1;
    Object localObject2;
    if (!bool)
    {
      if (this.c.containsKey("type"))
      {
        localObject1 = d("type");
        if (!bool) {
          if (((String)localObject1).equals("arc"))
          {
            this.h = new ub();
            if (bool) {
              break label480;
            }
            if (i1 == 0) {
              break label473;
            }
            if (!bool) {}
            q.n = !q.n;
          }
        }
        if (!bool) {
          if (((String)localObject1).equals("spline"))
          {
            this.h = new zb();
            if (bool) {
              break label480;
            }
            if (i1 == 0) {
              break label473;
            }
          }
        }
        if (!bool) {
          if (((String)localObject1).equals("bezier"))
          {
            this.h = new vb();
            if (bool) {
              break label480;
            }
            if (i1 == 0) {
              break label473;
            }
          }
        }
        if (!bool)
        {
          if (((String)localObject1).equals("quadCurve"))
          {
            this.h = new yb();
            if (bool) {
              break label480;
            }
            if (i1 == 0) {
              break label473;
            }
          }
          this.h = new xb();
        }
        if (bool) {
          break label480;
        }
        if (i1 == 0) {
          break label473;
        }
      }
      if (bool) {}
    }
    else if (this.c.containsKey("customconfiguration"))
    {
      localObject1 = d("customconfiguration");
      wb localwb = new wb();
      localwb.d((String)localObject1);
      if (!bool) {
        if (this.c.containsKey("userdata"))
        {
          if (bool) {
            break label423;
          }
          if (this.c.containsKey("userdataclass"))
          {
            localObject2 = d("userdata");
            String str = d("userdataclass");
            try
            {
              Object localObject3 = ib.c().a((String)localObject2, Class.forName(str));
              localwb.a(localObject3);
            }
            catch (Exception localException)
            {
              n.a("Could not parse userdata " + (String)localObject2 + " [" + str + "] " + localException);
            }
            catch (LinkageError localLinkageError)
            {
              n.a("Could not parse userdata " + (String)localObject2 + " [" + str + "] " + localLinkageError);
            }
          }
        }
      }
      label423:
      if (!bool) {
        if (this.k != null)
        {
          this.k.a(localwb);
          this.k = null;
        }
      }
      this.h = localwb;
      if (bool) {
        break label480;
      }
      if (i1 == 0) {
        break label473;
      }
    }
    this.h = new xb();
    label473:
    label480:
    if (!bool) {
      if ((this.h instanceof xb))
      {
        localObject1 = (xb)this.h;
        if (bool) {
          break label526;
        }
        if (c("smoothBends")) {
          ((xb)localObject1).d(true);
        }
      }
    }
    label526:
    if (!bool) {
      if (this.c.containsKey("quadCurveStraigtness"))
      {
        if (bool) {
          break label586;
        }
        if ((this.h instanceof yb))
        {
          ((yb)this.h).a(e("quadCurveStraigtness"));
          if (bool) {
            break label636;
          }
          if (i1 == 0) {
            break label625;
          }
        }
      }
    }
    label586:
    if (!bool) {
      if (this.c.containsKey("quadCurveStraightness"))
      {
        if (bool) {
          break label636;
        }
        if ((this.h instanceof yb)) {
          ((yb)this.h).a(e("quadCurveStraightness"));
        }
      }
    }
    label625:
    label636:
    if (!bool) {
      if (this.c.containsKey("fill")) {
        this.h.a(f.c(d("fill")));
      }
    }
    if (!bool)
    {
      if (this.c.containsKey("sourceArrow"))
      {
        this.h.c(i(d("sourceArrow")));
        if (bool) {
          break label764;
        }
        if (i1 == 0) {
          break label753;
        }
      }
      if (bool) {}
    }
    else if (!this.j.contains("first"))
    {
      if (bool) {
        break label764;
      }
      if (!this.j.contains("both")) {
        break label753;
      }
    }
    this.h.c(ab.f);
    label753:
    label764:
    if (!bool)
    {
      if (this.c.containsKey("targetArrow"))
      {
        this.h.b(i(d("targetArrow")));
        if (bool) {
          break label857;
        }
        if (i1 == 0) {
          break label846;
        }
      }
      if (bool) {}
    }
    else if (!this.j.contains("last"))
    {
      if (bool) {
        break label857;
      }
      if (!this.j.contains("both")) {
        break label846;
      }
    }
    this.h.b(ab.f);
    label846:
    if (!bool) {
      if (!c("reversedPathRendering"))
      {
        label857:
        if (bool) {
          break label909;
        }
        if (!c("reversePathRendering")) {
          break label882;
        }
      }
    }
    this.h.a(true);
    label882:
    this.h.a(c.a(a("width", 1), h(d("style"))));
    label909:
    if (!bool) {
      if (this.g != null)
      {
        if (bool) {
          break label1031;
        }
        if (this.g.size() > 2)
        {
          localObject1 = this.g.h();
          int n = this.g.size() - 2;
          ((a.c.y)localObject1).f();
          do
          {
            if (n <= 0) {
              break;
            }
            localObject2 = (w)((a.c.y)localObject1).j();
            ((a.c.y)localObject1).f();
            this.h.c(((w)localObject2).a(), ((w)localObject2).b());
            n--;
            if ((!bool) && (i1 != 0)) {
              break label1077;
            }
          } while (i1 == 0);
        }
      }
    }
    if ((!bool) && ((bool) || ((this.h instanceof ub))))
    {
      label1031:
      localObject1 = (ub)this.h;
      ((ub)localObject1).b(g(d("arcType")));
      ((ub)localObject1).a((float)e("arcRatio"));
      ((ub)localObject1).b((float)e("arcHeight"));
    }
    label1077:
    if (bool) {
      q.o = !q.o;
    }
  }
  
  public static byte g(String paramString)
  {
    if (!r.f) {
      if ("fixedHeight".equals(paramString)) {
        return 0;
      }
    }
    return 1;
  }
  
  public static byte h(String paramString)
  {
    boolean bool = r.f;
    if (!bool) {
      if ("line".equals(paramString)) {
        return 0;
      }
    }
    if (!bool) {
      if ("dashed".equals(paramString)) {
        return 1;
      }
    }
    if (!bool) {
      if ("dotted".equals(paramString)) {
        return 2;
      }
    }
    if (!bool) {
      if ("dashed_dotted".equals(paramString)) {
        return 3;
      }
    }
    return 0;
  }
  
  public tb f()
  {
    return this.h;
  }
  
  public Object c()
  {
    return this.h;
  }
  
  public static ab i(String paramString)
  {
    boolean bool = r.f;
    ab localab = (ab)l.get(paramString);
    if (!bool) {
      if (localab == null) {
        localab = ab.a(paramString);
      }
    }
    if (!bool) {
      if (localab == null) {
        localab = ab.f;
      }
    }
    return localab;
  }
  
  static
  {
    l.put("delta", ab.g);
    l.put("standard", ab.f);
    l.put("diamond", ab.i);
    l.put("short", ab.j);
    l.put("white_delta", ab.h);
    l.put("white_diamond", ab.k);
    l.put("none", ab.e);
    l.put("", ab.e);
    l.put("plain", ab.l);
    l.put("concave", ab.m);
    l.put("convex", ab.n);
    l.put("circle", ab.o);
    l.put("transparent_circle", ab.p);
    l.put("dash", ab.q);
    l.put("skewed_dash", ab.r);
    l.put("t_shape", ab.s);
    l.put("crows_foot_one_optional", ab.v);
    l.put("crows_foot_many_optional", ab.w);
    l.put("crows_foot_one_mandatory", ab.t);
    l.put("crows_foot_many_mandatory", ab.u);
    l.put("crows_foot_one", ab.x);
    l.put("crows_foot_many", ab.y);
    l.put("crows_foot_optional", ab.z);
  }
  
  private static class a_
    extends r
  {
    private Map g = new HashMap();
    
    private a_() {}
    
    public void a(String paramString)
    {
      super.a(paramString, new r());
      super.a(paramString);
    }
    
    public void a(r paramr)
    {
      boolean bool = r.f;
      int i = r.e;
      super.a(paramr);
      String str1 = paramr.d("name");
      String str2 = paramr.d("binaryValue");
      if (!bool) {
        if (str2.length() > 0)
        {
          localObject = kb.a().a(str2);
          if (bool) {
            break label74;
          }
          this.g.put(str1, localObject);
          if (i == 0) {
            return;
          }
        }
      }
      label74:
      Object localObject = paramr.d("valueClass");
      String str3 = paramr.d("value");
      if (!bool) {
        if (((String)localObject).length() > 0)
        {
          try
          {
            this.g.put(str1, ib.c().a(str3, Class.forName((String)localObject)));
          }
          catch (ClassNotFoundException localClassNotFoundException)
          {
            if (bool) {
              break label160;
            }
          }
          localClassNotFoundException.printStackTrace(System.err);
          if (i == 0) {
            return;
          }
        }
      }
      label160:
      this.g.put(str1, null);
    }
    
    public void a(wb paramwb)
    {
      boolean bool = r.f;
      int i = r.e;
      Iterator localIterator = this.g.entrySet().iterator();
      if (localIterator.hasNext()) {}
      while (bool)
      {
        Map.Entry localEntry = (Map.Entry)localIterator.next();
        paramwb.a((String)localEntry.getKey(), localEntry.getValue());
        if ((!bool) && (i != 0)) {
          return;
        }
        if (i == 0) {
          break;
        }
      }
      this.g.clear();
    }
    
    a_(s.1 param1)
    {
      this();
    }
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.e.a.s

 * JD-Core Version:    0.7.0.1

 */